<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
	<head>
		<title>个人信息</title>
		<%@include file="/WEB-INF/base2.jspf"%>
		<script src="//at.alicdn.com/t/font_621086_w750avfudnc7syvi.js"></script>
		<script src="/js/clipboard.min.js"></script>
		<!-- <script src="/cp2/js/iscroll.js" type="text/javascript" charset="utf-8"></script> -->
		<script src="/js/clipboard.min.js"></script>
		<style type="text/css">
		/* 1rem=50px    */
			body{
				position: relative;
				font-size: 62.5%!important;
				}
			#wrapper{
			 left:0;
			 top:0;
			 position: absolute; 
/* 			 overflow: hidden;
			 height: 100%;
			 box-sizing: border-box;
			  */
			 width: 100%;
			 padding: 0rem 0.4rem ;
			 }
			#scroller{
				/*position: absolute;
				left: 0;
				top: 0;*/
				margin-top: 0.7rem;
				display: flex;
				flex-direction: column;
				}
			.jinri{
				width: 100%;
				display: flex;
				flex-direction: row;
				background-color: #fbfbfb;
				margin-top: 0.08rem;
			}
			.jinri .dt{
				width: 38%;
				background-color: #efefef;
				font-weight: 400;
				font-size: 18px ;
				color: #545454;
				box-sizing: border-box;
				padding:6px;
				display:inline-flex;
				align-items:center;				
			}
			.jinri .dd{
				width: 62%;
				color: #545454;
				font-size: 18px;
				box-sizing: border-box;
				padding-left: 0.3rem;
				display:inline-flex;
				align-items:center;
			}
			.main-button{
				height: 0.76rem;
				width: 6.72rem;
				display: flex;
				flex-direction: row;
				align-content: center;
				justify-content: center;
				margin: 0.4rem;
			}
			.baocun{
				width: 3.2rem;
				height: 0.74rem;
				font-size: 0.32rem;
			}
			.imgWrapper ,.imgWrapper img{
				width: 6.7rem;
				height: 4.46rem;
			}
			#daliDetail{
				padding:0.2rem;
				margin:10px auto;
				width:2.5rem;
				text-align:center;
				border:1px solid #ccc;
				background:#fff;
				border-radius: 10px;
				color:#000;	
				cursor: pointer;
			}
			
			#daliDetail:hover{
				background: #337ab7;
				border:1px solid #337ab7;
				color:#fff;	
			}
			
			.DLtitle{
				margin-top:50px;
				display: flex;
				justify-content: flex-start;
				align-items: center;
				padding:0.24rem 0;
			}	
			
			#login_icon{
				display: flex;
			    color: #fff;
			    font-size: 36px;
			    -ms-flex-align: center;
			    align-items: center;
			    -ms-flex-pack: center;
			    justify-content: center;
			    border-radius: 50%;
			    width: 72px;
			    height: 72px;
			    background-color: rgb(255, 99, 102);
			     margin-right:30px;
			}
			/* #user_message{
				margin-top: 0.12rem;
			} */
			#user_message div{
				
				margin: 15px 0;	
			}
			#user_message span{
				font-size: 17px;
			}
			#user_message div em{
    			color: #999;
    			font-size: 19px;
			}
			.icon {
		       width: 1em; height: 1em;
		       vertical-align: -0.15em;
		        fill: currentColor; 
		       font-size:0.3rem;
		       font-weight:900;
		       overflow: hidden;
		      
		    }
		    
		    .daili_list{
		     	position: relative; 
		     	margin-left: -15px !important;
		     	margin-right: -15px !important;
		     	margin-top: 30px;
		    }
		    
		    .daili_list_item{
		    	position: relative;
		    	font-size: 17px;
		    }
		    .daili_list_item  a{
			  display:flex;
			  overflow: hidden;
			  display: -ms-flexbox;
		      overflow: hidden;
		      vertical-align: middle;
	    	  transition: background-color .2s;
		      -ms-flex-align: center;
		      align-items: center; 
	    	  border-bottom: 1px solid #eeeeee;
	    	  display: flex;
		      min-height: 44px;
		      background-color: #fff;
		      padding:0 15px;
		    }
		    
		    .daili_list_content{
		    	line-height: 0.3rem; 
			    width: auto;
			    overflow: hidden;
			    text-overflow: ellipsis;
			    white-space: nowrap;
			    padding-top: 7px;
			    padding-bottom: 7px;
			    font-size: 17px;
		    }
		    .copy{
			   display:inline-block;
			   float:right;
			   font-size: 16px; 
			   margin-bottom: 5px;
		    }	
		   .tuig-link{
	   		  display:inline-block;
	   		 float:left;
		   	font-size: 16px;
		   	padding: 5px; 
		   	margin-top: 5px;
		   }
		    .tips{
		   	color:red;
		   } 
		  
		/*   .btn-default{
		  	padding: 1px 10px;
		  } */
 
		</style>
	</head>

	<body >
		<div class="col-xs-12 col-sm-4 col-sm-offset-4 text-center" style="color:white;background: #059BF3;height: 50px;line-height:50px;position: fixed;margin-top: 0px;left: 0px;z-index: 100;padding-left:0;padding-right:0;">
			<a onclick="back()" class="glyphicon glyphicon-chevron-left fl" style="cursor:pointer; color: white;position:absolute;top:50%;transform:translateY(-50%);font-size: 20px;left:10px;"></a>
			<strong style="font-size: 20px;">代理中心</strong>
		</div>
		<div class="col-xs-12 col-sm-4 col-sm-offset-4" style="background: #f5f5f5;height: 100%;" >
			<div class="DLtitle">
				<div id="login_icon">G4</div>
				<div id="user_message">
					<div>
						<span>用户名：</span>
						<em id="userName">${user.name} </em>
					</div>
					<div>
						<span>账户余额：</span>
						<em id="userMoney">${user.balance} </em>
					</div>
					<%-- <div>
						<span>推广链接：</span>	
						<em id="icode" readonly >${user.icode}</em>
						<button class="btn btn-default" data-clipboard-action="copy" data-clipboard-target="#icode" id="copy_btn">复制</button>
						 <input class="form-control"  value="${user.icode}" id="icode" readonly />
						<button class="btn btn-default" data-clipboard-action="copy" data-clipboard-target="#icode" id="copy_btn" onclick="copyContent();">复制</button> 
					</div>  --%>
				</div>
			</div>
			
			
			<div class="div-link">
				<span class="tuig-link">推广链接：</span>
				 <button class="btn btn-default copy"  data-clipboard-action="copy" data-clipboard-target="#icode" id="copy_btn" onclick="copyContent();">复制</button>
				 <input class="form-control"  value="${user.icode}" id="icode" readonly />
				
			</div>
			
			
			 <!--  <input type="text" class="share-input"  value="http://www.youtube.com" id="copy-content"  readonly /> 
      <button class="copy-button" type="button" onclick="copyContent();"> 复制 </button>  -->




      
			<%-- <!-- <div class="div-link"> -->
				<span class="tuig-link">推广链接：</span>
				 <input class="form-control"  value="${user.icode}" id="icode" readonly />
				 <button class="btn btn-default" data-clipboard-action="copy" data-clipboard-target="#icode" id="copy_btn">复制</button>
			<!-- </div> --> --%>
			<div class="tips"></div>
			<div class="daili_list">
				<div class="daili_list_item">
					<a href="/agent/agentExplanPage.do">  
						<div class="daili_list_content">代理说明</div>
						<svg class="icon right" aria-hidden="true" style="margin-left:auto;">
						    <use xlink:href="#icon-right"></use>
						</svg>		
					</a>
				</div>
				
				<div class="daili_list_item">
					<a href="/agent/agentUserPage.do">
						<div class="daili_list_content">用户管理</div>
						<svg class="icon right" aria-hidden="true" style="margin-left:auto;">
						    <use xlink:href="#icon-right"></use>
						</svg>
					</a>
				</div>
				
				<div class="daili_list_item">
					<a href="/agent/agentCommisionPage.do">
						<div class="daili_list_content">代理佣金</div>
						<svg class="icon right" aria-hidden="true" style="margin-left:auto;">
						    <use xlink:href="#icon-right"></use>
						</svg>
					</a>
				</div>
				
				<div class="daili_list_item">
					<a href="/agent/agentReportFromPage.do">
						<div class="daili_list_content">报表设计</div>
						<svg class="icon right" aria-hidden="true" style="margin-left:auto;">
						    <use xlink:href="#icon-right"></use>
						</svg>
					</a>
				</div>
			</div>
			
		</div>
		
		<!-- <div class="col-xs-12 col-sm-4 col-sm-offset-4 text-center " style="background: white;"style="position:relative;"> -->
			<!-- <div id="wrapper"  class="">
				
		<br>
		<br>
		        <div id="scroller" style="margin-bottom: 20px;" class="col-xs-12 col-sm-4 col-sm-offset-4">
		        <div id="daliDetail">代理详情</div>
		        <span style="font-size:12px;color:red;display:inline-block;margin-bottom:1vh;">&nbsp;&nbsp;&nbsp;*信息提示:</span>
		        <span style="font-size:12px;color:red;display:inline-block;margin-bottom:1vh;">&nbsp;&nbsp;&nbsp;*所有代理返点收益将会每天自动转入账户余额</span>
					<dl class="jinri">
						<dt class="dt">今日收益</dt>
						<dd class="dd">￥<span id="jinri"></span></dd>
					</dl>
					<dl class="jinri">
						<dt class="dt">昨日收益</dt>
						<dd class="dd">￥<span id="zuori"></span></dd>
					</dl>
					<dl class="jinri">
						<dt class="dt">所有收益</dt>
						<dd class="dd">￥<span id="suoyou"></span></dd>
					</dl>
					<div type="button" class="kd-button main-button">
						<a href="wodetuiguangyonghu.html"><button type="button" class="btn btn-success baocun">我的推广用户</button></a>
					</div>
					<p style="font-size: 0.28rem;width: 100%;color: #000;margin-top: 0.6rem;"></p>		
					<div class="" style="width:100%;display:flex;">
						<input class="form-control" placeholder="专属推广链接" id="icode" readonly />
						<button class="btn btn-default" data-clipboard-action="copy" data-clipboard-target="#icode" id="copy_btn">复制</button>
					</div>	
					
						
		            <h2 style="font-size: 0.32rem;width: 100%;font-weight: bold;color: #000;margin-top: 0.6rem;">推荐分成介绍</h2>
		            <p style="font-size: 0.28rem;width: 100%;color: #000;margin-top:0.2rem;">“SB网投”高分成三级金字塔代理模式介绍：</p>
				    <div class="imgWrapper">
						<img src="/cp2/img/dailituiguang.png"/>
					</div>
					
					<dl style="font-size: 0.28rem;width: 100%;color: #000;margin-top: 20px;">
						<dt style="">如何推广？</dt>
						<dd style="margin-left: 0.4rem;">1.注册成为公司会员</dd>
						<dd style="margin-left: 0.4rem;">2.我的地盘</dd>
						<dd style="margin-left: 0.4rem;">3.推广中心</dd>
						<dd style="margin-left: 0.4rem;">4.复制专属推广链接，然后分享给你的朋友。</dd>
					</dl>
					<dl style="font-size: 0.28rem;width: 100%;color: #000;margin-top: 0.4rem;">
						<dt style="">推广比例分成：</dt>
						<dd style="margin-left: 0.4rem;">1.&nbsp;如A推荐B成为公司有效会员后A可获得B产生有效打码量的5%提成。</dd>
						<dd style="margin-left: 0.4rem;">2.B推荐C成为公司有效会员后B可获得C产生有效打码量的5%提成,，A可获得C产生有效打码量的3%提成。</dd>
						<dd style="margin-left: 0.4rem;">3.C推荐D成为公司有效会员后C可获得D产生有效打码量的0.2%提成,B可获得D产生有效打码量的3%提成。</dd>
						<dd style="margin-left: 0.4rem;">4.此代理模式为三层关系,即A推荐B、B推荐C、A到C三者之间有存在推广分红，C推荐D，则D跟A不存在推广分红关系，但B跟D仍存在推广分红关系!</dd>
					</dl>
					 <p style="font-size: 0.28rem;width: 100%;color: #000;margin-top:0.2rem;"><span style="color: red;">注：</span>如发现会员与多个账号,或者与其他平台进行对打，产生非法打码，将取消推广分红资格并且没收一切彩金包含本金!</p>
					 
					 
		       </div>
		</div>
		</div> -->
		
<div class="modal-div-fakeModal" id="div-i-noticeGenDan">
	<div class="div-c-modalContent">
		<h3 class="fakemodal-title"></h3>
		<div class="fakemodal-content"></div>
		<div class="fakemodal-btnsGroup"><button class="btn btn-default btn-class-closeFakeModal">关闭</button></div>
	</div>
</div>			
				<script type="text/javascript">
			function jianrong() {
				/* 动态设置 html font-size, 使用 rem 适配 */
				var htmlSelector = document.documentElement
				var width = htmlSelector.clientWidth
				if (width > 600) {
					width = 600
				}
				var fSize = width / 7.5
				htmlSelector.style.fontSize = String(fSize) + "px"
				htmlSelector.dataset.fontrem = fSize.toFixed(2)
			}
			jianrong();
			
			var agent_id = '${user.agent_id}';
			function getIcode(){
				ajax({
					url:"/u/yqm.do",
					success:function(data){
						var json=eval('('+data+')');
						$("#icode").val(json.message);
						$(this).remove();
					}
				});
			}		
			
			if ("${user.state}" === "2") {
				showNormalNoticeModal("#div-i-noticeGenDan", "提示：", "试玩账号无法进行推广，请注册为正式账号")
			} else {
				/* if(agent_id!=''){
					$(".div-link")[0].style.display="none"; 
					$(".tips")[0].style.display="block";
					$(".tips").text("想要成为代理，请联系客服！"); 
				}else{ */
					$(".div-link")[0].style.display="block"; 
					$(".tips")[0].style.display="none";
					getIcode(); 
				//}
			}
	      
	       
	       
	       function copyContent(){ 
		       showNormalNoticeModal("#div-i-noticeGenDan", "提示：", "复制成功！")
	    	   var clipboard = new ClipboardJS('#copy_btn');      
		       clipboard.on('success', function(e) {      
		           e.clearSelection();      
		       })	
		       
    };
  
    
    



    	 
    
		</script>
	</body>
</html>